Fix NMI race with context switch.
authorkaf24@firebug.cl.cam.ac.uk <kaf24@firebug.cl.cam.ac.uk>
Thu, 20 Oct 2005 10:25:55 +0000 (11:25 +0100)
committerkaf24@firebug.cl.cam.ac.uk <kaf24@firebug.cl.cam.ac.uk>
Thu, 20 Oct 2005 10:25:55 +0000 (11:25 +0100)
commit27a9d6d6143f17e2cc2f6426b8a1e2843f7fe705
tree28b903ff78f4229a43f21e77d7811f5463c4c0bd
parent81e869fdc672d0d2126c0ad2e4338fb971b81b85
Fix NMI race with context switch.

The machine used to auto reboot if an NMI was received in a critical
time window when context switching domains. There is a small time
window when the GDT may become unmapped (after CR3 is updated and
before setting GDTR with the new GDT during a domain context
switch. If an NMI is received during this time window a triple fault
is triggered causing the machine to auto reboot.

Bug found and original patch proposed by Jose Renato Santos
<jsantos@hpl.hp.com>.

Signed-off-by: Keir Fraser <keir@xensource.com>
xen/arch/x86/domain.c
xen/arch/x86/setup.c